<winstate> : Change Window State

Changes window's state.

Syntax: 

<winstate>("WinTitle", "State")

WinTitleOrHWND
Title of the window to activate or HWND.  HWND is a unique handle Windows internally uses to identify each window.  The HWND can be retrieved by some commands (<wininfo>, <win_enumerate>) or is provided by some system variables (_vKeybdFocusWindow_HWND, _vActiveWindow_HWND, _vActiveWindowPrev_HWND).

State
Can be one of these values:
"MIN"
"RESTORE"
"MAX"
"ALWAYS_TOP"
"NOT_ALWAYS_TOP"
"HIDE"
"SHOW"

Example: 

<#> This macro minimizes "Notepad" window
<#>
<cmds>

<if_win>("Notepad","OPEN",0)
   <winstate>("Notepad","MIN")
<else>
   <msg>(100,100,"'Notepad' is not opened!","Message",1)
<endif>